﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace WoodManager.Header
{
  public struct StructDinhMucVatTuSon
    {
        public String sID;
        public String sVatTuSon;
        public Double sDinhLuong;
        public String sGhiChu;
        public StructDinhMucVatTuSon(String ID,
                                    String VatTuSon,
                                    Double DinhLuong,
                                    String GhiChu)
        { 
            sID = ID;
            sVatTuSon = VatTuSon;
            sDinhLuong = DinhLuong;
            sGhiChu = GhiChu;          
        }
        public void SetValue(String ID,
                            String VatTuSon,
                            Double DinhLuong,
                            String GhiChu)
        {
            sID = ID;
            sVatTuSon = VatTuSon;
            sDinhLuong = DinhLuong;
            sGhiChu = GhiChu;
        }
    }

	public struct StructVanVatLieu
	{
		public string sIDVan, sNhomVan, sTenMauVan, sMatHoanThien, sNhaCungCap;

		public double dDoDay, dKtDai, dKtRong;

		public string sGhiChu;
	}

    public struct StructDeXuatVan
    {
		public string sDHID, sHMSPID, sVersion, sMaLoiVan, sMaCHiTiet, sThanhPhan, sTenChiTiet ,dDai, dRong, dSau,
                dSL, sPhuMat1, sPhuMat2, sChiCanh, sSoCanh, sNVDeXuat, sGhiChu;

        public void setValue(string donhang, string hangmuc, string ver)
        {
            sDHID = donhang;
            sHMSPID = hangmuc;
            sVersion = ver;
        }
	}
    public static class WoodManagerHeader
    {
        public const string
            //Phieu de xuat van theo thanh phan
            RP_NAME_DXV_THANH_PHAN = "DXV001",
            PATH_REPORT_DEXUATVAN_TP = @"Reports\DXV001.rpt",

            //Phieu de xuat van theo loai van
            RP_NAME_DXV_LOAI_VAN = "DXV002",
            PATH_REPORT_DEXUATVAN_LV = @"Reports\DXV002.rpt";

        public const String           
            VW_DXV_DANH_MUC_VAN    =   "DanhMucVan", 
            VW_DXV_ID_VAN          =   "IDVan",
            VW_DXV_TEN_MAU_VAN     =   "TenMauVan", 
            //VW_DXV_DO_DAY          =   "DoDay",
            VW_DXV_DAI             =   "Dai",
            VW_DXV_RONG            =   "Rong", 
            VW_DXV_SO_LUONG        =   "SoLuong",
            VW_DXV_DIEN_TICH       =   "DienTich", 
            VW_DXV_SON_PHU_1       =   "SonPhu1", 
            VW_DXV_DIEN_TICH_1     =   "DienTich1", 
            VW_DXV_SON_PHU_2       =   "SonPhu2", 
            VW_DXV_TEN_CHI_CANH    =   "TenChiCanh", 
            VW_DXV_SO_CANH         =   "CHITIET",
            VW_DXV_CHIEU_DAI_CC    =   "ChieuDaiChiCanh",
            VW_DXV_HMSP_ID         =   "HMSPID", 
            VW_DXV_DH_ID           =   "DHID", 
            VW_DXV_NV_DE_XUAT      =   "NVDeXuat", 
            VW_DXV_NV_NHAN         =   "NVNhan", 
            VW_DXV_VERSION         =   "Version",
            VW_DXV_THANH_PHAN      =   "ThanhPhan",
            VW_DXV_ID              =   "ID";

        public const String 
            DXV_THANHPHAN       = "ThanhPhan",
            DXV_IDVAN           = "IDVan",
            DXV_DANHMUCVAN      = "DanhMucVan",
            DXV_MALOIVAN        = "MaLoiVan",
            DXV_DAI             = "Dai",
            DXV_RONG            = "Rong",
            DXV_SOLUONG         = "SoLuong",
            DXV_PHUMAT1         = "PhuMat1",
            DXV_PHUMAT2         = "PhuMat2",
            DXV_CHICANHID       = "ChiCanhID",
            DXV_SOCANH          = "SoCanh",
            DXV_CHIEUDAICHICANH = "ChieuDaiChiCanh",
            DXV_HMSPID          = "HMSPID",
            DXV_NVDEXUAT        = "NVDeXuat",
            DXV_NVNHAN          = "NVNhan",
            DXV_VERSION         = "Version",
            DXV_ID              = "ID";

        public static String[] DXV_COL_NAME =
                            {
                                DXV_THANHPHAN,
                                DXV_IDVAN,
                                DXV_DANHMUCVAN,
                                DXV_MALOIVAN,
                                DXV_DAI,
                                DXV_RONG,
                                DXV_SOLUONG,
                                DXV_PHUMAT1,
                                DXV_PHUMAT2,
                                DXV_CHICANHID,
                                DXV_SOCANH,
                                DXV_CHIEUDAICHICANH,
                                DXV_HMSPID,
                                DXV_NVDEXUAT,
                                DXV_NVNHAN,
                                DXV_VERSION,
                                DXV_ID
                            };

        public const int
            VWDXV_DANH_MUC_VAN_TAG      = 0,
            VWDXV_ID_VAN_TAG            = 1,
            VWDXV_TEN_MAU_VAN_TAG       = 2,
            VWDXV_DAI_TAG               = 3,
            VWDXV_RONG_TAG              = 4,
            VWDXV_SO_LUONG_TAG          = 5,
            VWDXV_TONG_SL_TAG           = 6,
            VWDXV_DIEN_TICH_TAG         = 7,
            VWDXV_SON_PHU_1_TAG         = 8,
            VWDXV_DIEN_TICH_1_TAG       = 9,
            VWDXV_SON_PHU_2_TAG         = 10,
            DXV_TEN_CHI_CANH_TAG        = 11,
            DXV_SO_CANH_CC_TAG          = 12,
            DXV_CHIEU_DAI_CC_TAG        = 13,
            DXV_HMSP_ID_TAG             = 14,
            DXV_DH_ID_TAG               = 15,
            DXV_NV_DE_XUAT_TAG          = 16,
            DXV_NV_NHAN_TAG             = 17,
            DXV_VERSION_TAG             = 18,
            DXV_THANH_PHAN_TAG          = 19,
            VWDXV_ID_TAG                = 20;



        //View ToHopVanSon
        public const String VW_TO_HOP_VAN_SON = "ViewToHopVanSon";
        public  const String    
            THVS_ID_VAN_SON     = "IDToHopSon",
            THVS_ID_VAN         = "IDVan",
            THVS_ID_SON         = "IDSon",
            THVS_TEN_VAN        = "TenMauVan",
            THVS_TEN_SON        = "TenSonPhu",
            THVS_GHI_CHU        = "GhiChu";

        //View DinhMucVatTuSon
        public const String 
            TB_DINH_MUC_SON     = "DinhMucSon",
            DMS_ID_TO_HOP_SON   = "IDToHopSon",
            DMS_MA_VAT_TU_SON   = "MaVatTuSon",
            DMS_DINH_LUONG      = "DinhLuong",
            DMS_GHI_CHU         = "GhiChu";

        //Table Chi canh
        public const String
            TB_CC_ID_CHI_CANH   = "IDChiCanh",
            TB_CC_MA_NCC        = "MaNCC",
            TB_CC_MA_NK         = "MaNK",
            TB_CC_NHOM_CHI_CANH = "NhomChiCanh",
            TB_CC_TEN_CHI_CANH  = "TenChiCanh";

        // Table Van Loi
        public const string
            TB_VAN_LOI          = "VanVatLieu";

        public const string
					VANVL_IDVAN					= "IDVan",
					VANVL_NHOMVAN				= "NhomVan",
					VANVL_TENMAUVAN			= "TenMauVan",
					VANVL_MATHOANTHIEN	= "MatHoanThien",
					VANVL_NHACUNGCAP		= "NhaCungCap",
					VANVL_DODAY					= "DoDay",
					VANVL_KTDAI					= "KtDai",
					VANVL_KTRONG				= "KtRong",
					VANVL_GIATHAMKHAO		= "GiaThamKhao",
					VANVL_GHICHU				= "GhiChu";


        // Table So chi canh
        public const String
            TB_SO_CANH_SON_ID = "ID",
            TB_SO_CANH_SON_CHI_TIET = "ChiTiet";

    }
}
